<template>
	<el-dialog
		:title="`德州增值服务费明细`"
		:visible="visible"
		width="350px"
		class="rempadding"
		:destroy-on-close="true"
		:before-close="handleClose"
		@close="handleClose"
	>
		<el-divider></el-divider>
		<el-row class="contentBox">
			<el-col :span="5">代理账号: {{ curData.proxyName }}</el-col>
			<el-col :span="4">代理层级: {{ curData.proxyLevel }}</el-col>
			<el-col :span="5">直属上级: {{ curData.parentProxyName }}</el-col>
			<el-col :span="5">总代理: {{ curData.topProxyName }}</el-col>
			<el-col :span="5">
				业务模式:
				{{ mappingBusinessModel(businessModelData.businessModel) }}
			</el-col>
		</el-row>
		<div class="itemBox">
			<div class="item">
				<div class="s1">发弹幕</div>
				<div class="s2">
					{{
						handleTotalNumber(
							'USDT',
							curData.valueAddedBarrageAmount
						)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">发表情</div>
				<div class="s2">
					{{
						handleTotalNumber('USDT', curData.valueAddedEmojiAmount)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">发短语</div>
				<div class="s2">
					{{
						handleTotalNumber('USDT', curData.valueAddedShortAmount)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">发语音</div>
				<div class="s2">
					{{
						handleTotalNumber('USDT', curData.valueAddedVoiceAmount)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">互动道具</div>
				<div class="s2">
					{{
						handleTotalNumber('USDT', curData.valueAddedPropsAmount)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">看公牌</div>
				<div class="s2">
					{{
						handleTotalNumber(
							'USDT',
							curData.valueAddedPubcardAmount
						)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">保险行动延时</div>
				<div class="s2">
					{{
						handleTotalNumber(
							'USDT',
							curData.valueAddedInsureDelayAmount
						)
					}}
				</div>
			</div>
			<div class="item">
				<div class="s1">下注行动延时</div>
				<div class="s2">
					{{
						handleTotalNumber(
							'USDT',
							curData.valueAddedBetDelayAmount
						)
					}}
				</div>
			</div>
		</div>
	</el-dialog>
</template>

<script>
import list from '@/mixins/list'

export default {
	components: {},
	mixins: [list],
	props: {
		curData: {
			type: Object,
			default: {}
		},
		visible: {
			type: Boolean,
			default: false
		},
		handleVisible: {
			type: Object,
			default: () => {}
		}
	},
	data() {
		return {
			businessModelData: '',
			loading: false,
			tableHeight: 480,
			data: []
		}
	},
	mounted() {
		this.getData()
	},
	methods: {
		// 获取代理账号信息
		getData() {
			// this.loading = true
			// this.$api
			// 	.proxyIncomeAuditDetail({ id: this.curData.orderNo })
			// 	.then((res) => {
			// 		this.loading = false
			// 		this.data =
			// 			(res.data.fundsAuditDetailRespList &&
			// 				res.data.fundsAuditDetailRespList.filter(
			// 					(ele) => !ele.venueName.includes('德州')
			// 				)) ||
			// 			[]
			// 	})
			// 	.catch(() => {
			// 		this.loading = false
			// 	})
			// 获取业务模式
			this.$api
				.getProxyDetailQueryDetail({
					merchantId: this.curData.merchantId,
					userName: this.curData.proxyName
				})
				.then((res) => {
					if (res?.code === 200) {
						this.businessModelData = res.data || {}
					}
				})
		},
		handleClose() {
			this.$emit('update:visible', false)
		}
	}
}
</script>
<style lang="scss" scoped>
.itemBox {
	margin: 0 auto;
	width: 300px;
	border: 1px solid #dedede;
	.item {
		display: flex;
		border-bottom: 1px solid #dedede;
		height: 35px;
		align-items: center;
		padding: 0 20px;
		&:last-child {
			border-bottom: 0;
		}
		div {
			flex: 1;
			width: 100%;
			height: 100%;
			display: flex;
			align-items: center;
			justify-content: center;
		}
	}
	.s1 {
		border-right: 1px solid #dedede;
	}
}
</style>
